/* 主题变量定义 */
:root {
  --bg-app: #f0f4f8;
  --text-primary: #303133;
  --text-secondary: #606266;
  --text-muted: #909399;
  --panel-bg: rgba(255, 255, 255, 0.9);
  --panel-subtle: rgba(255, 255, 255, 0.5);
  --panel-weak: rgba(245, 247, 250, 1);
  --border-color: rgba(228, 232, 236, 0.8);
  --card-bg: #ffffff;
  --shadow-weak: rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] {
  --bg-app: #0f1216;
  --text-primary: #e5e7eb;
  --text-secondary: #c7c9cf;
  --text-muted: #9aa0a6;
  --panel-bg: rgba(22, 27, 34, 0.9);
  --panel-subtle: rgba(22, 27, 34, 0.6);
  --panel-weak: #151a21;
  --border-color: rgba(99, 110, 123, 0.35);
  --card-bg: #161b22;
  --shadow-weak: rgba(0, 0, 0, 0.4);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body {
  background-color: var(--bg-app);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

.ipad-container {
  max-width: 1024px;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--bg-app) 0%, #d7e3f0 100%);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 10px 30px var(--shadow-weak);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* 顶部导航栏样式 */
.nav-tabs {
  display: flex;
  background: var(--panel-bg);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  padding: 0;
  position: relative;
  z-index: 20;
}

.nav-tabs::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, #3498db, #2c82c9, #1abc9c);
  z-index: 1;
}

.nav-tab {
  padding: 16px 24px;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  cursor: pointer;
  transition: all 0.3s;
  text-align: center;
  flex: 1;
  text-decoration: none;
}

.nav-tab.active {
  color: #409EFF;
  font-weight: 600;
}

.nav-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: #409EFF;
  border-radius: 3px 3px 0 0;
}

.nav-tab-icon {
  margin-right: 8px;
  font-size: 18px;
  vertical-align: middle;
}

/* 系统标题样式 */
.system-title {
  text-align: center;
  padding: 24px;
  position: relative;
  background: var(--panel-subtle);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.title-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 1;
}

.subtitle {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 1px;
  margin-bottom: 6px;
  text-transform: uppercase;
}

.main-title {
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
  position: relative;
  padding: 0 15px;
}

.main-title::before,
.main-title::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 30px;
  height: 2px;
  background: linear-gradient(90deg, #3498db, rgba(52, 152, 219, 0));
  transform: translateY(-50%);
}

.main-title::before {
  left: -20px;
}

.main-title::after {
  right: -20px;
  background: linear-gradient(90deg, rgba(52, 152, 219, 0), #3498db);
}

/* 主体内容 */
.main-content {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* 响应式设计 */
@media (max-width: 1180px) {
  .ipad-container {
    border-radius: 0;
  }
}

/* 深色主题覆盖：尽量不入侵组件样式，仅做容器级覆盖 */
[data-theme="dark"] body {
  background-color: var(--bg-app);
  color: var(--text-primary);
}

[data-theme="dark"] .nav-tabs {
  background: var(--panel-bg);
  border-bottom-color: var(--border-color);
}

[data-theme="dark"] .nav-tab.active {
  color: #8ab4ff;
}

[data-theme="dark"] .system-title {
  background: var(--panel-subtle);
  border-bottom-color: var(--border-color);
}

/* 常用卡片与面板 */
[data-theme="dark"] .data-card,
[data-theme="dark"] .final-result-text,
[data-theme="dark"] .records-section,
[data-theme="dark"] .video-player-section,
[data-theme="dark"] .video-list-section {
  background: var(--card-bg) !important;
  box-shadow: 0 8px 20px var(--shadow-weak) !important;
}

[data-theme="dark"] .player-header,
[data-theme="dark"] .list-header {
  background: rgba(22, 27, 34, 0.8) !important;
  border-bottom: 1px solid var(--border-color) !important;
}

[data-theme="dark"] .video-info-panel,
[data-theme="dark"] .record-controls {
  background: #11161c !important;
  border-color: var(--border-color) !important;
}

[data-theme="dark"] .records-table :is(th, td) {
  color: var(--text-secondary) !important;
}

[data-theme="dark"] .records-table :deep(.el-table__header) {
  background-color: #11161c !important;
}

@media (max-width: 768px) {
  .nav-tab {
    padding: 12px;
  }

  .nav-tab-text {
    display: none;
  }

  .system-title {
    padding: 12px;
  }

  .main-title {
    font-size: 20px;
  }

  .subtitle {
    font-size: 12px;
  }
} 